Skip to content

fix(stop-gate): no release by indented code or by the bot under an owner account (0.2.2) - #19

Merged
ellmos-multi-bot merged 2 commits into
mainfrom
fix/stop-gate-0.2.2
Nov 22, 2026
Merged

ellmos-multi-bot merged 2 commits into
mainfrom
fix/stop-gate-0.2.2

Conversation

@lukisch

@lukisch lukisch commented Nov 22, 2026

Copy link
Copy Markdown
Contributor

Summary

Follow-up to #18 (STOPP gate), release 0.2.2.

  • Indented code block: a line indented by a tab or four spaces never counts as a release, like fenced and quoted lines.
  • Owner account: if the bot writes under an owner account (multi_bot.owner_fallback: true, or merge_account listed in policy.stop_release_accounts), issue.comment, pr.review and api.request on comment/review endpoints refuse any body that contains a release line. This means the bot cannot lift a stop as the owner. The private wrapper sets owner_fallback in its fallback layer (separate PR in the private instance).
  • Labels with auto-merge effect: I searched the workflows of the maintained organisations (code search with a positive control). None merges on a label, so no label refusal is added.
  • Prompt: a release is its own comment and contains only the formula line. No other stop signal may appear in it, otherwise the comment counts as a new STOPP. Today's second review tripped over exactly this.
  • Version and changelog: version 0.2.2 (__init__, README EN/DE, module manifest). The CHANGELOG entry covers fix(policy): hold approve and merge on unlifted STOPP signals #18 and this fix. A stray trailing ## Unreleased section is folded into 0.2.2.
  • Separate commit: it certifies a foreign uncommitted change from the canonical clone, the umlaut in the CONTRIBUTING heading (TASKSOLVER #529). The run notes that had been appended to CHANGELOG are archived locally, not committed.

The v0.2.2 tag is set by the merging instance after the merge.

Ticket T-20261122-473151443.

Test plan

  • tests/test_stop_gate.py: 46 passed. New probes cover indented and tab-indented formulas, plus owner-account refusal across 4 write paths and 2 trigger configurations. Negative controls: quoted formula, labels, and no owner account.
  • Mutation check: disabling the indented-code check makes 2 tests fail; making the owner condition always true makes 4 fail.
  • Full suite 534 passed, 2 skipped; ruff check and ruff format --check clean.
  • Independent review on the exact head

🤖 Generated with Claude Code

https://claude.ai/code/session_01THB2EyNYw5th8eXvfU8evh

Lukas Geiger and others added 2 commits November 22, 2026 23:45
Uncommitted edit found in the canonical clone (TASKSOLVER #529,
2026-11-01): "koennen" -> "können" in the German heading. Diff read; it is
the only change and matches the documented task. The accompanying
TASKWRITER/TASKSOLVER run notes that had been appended to CHANGELOG.md are
run logs, not changelog entries; they are archived locally instead of
committed.

Ticket: T-20261122-473151443

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01THB2EyNYw5th8eXvfU8evh
…ner account (0.2.2)

- An indented code block line (tab or four spaces) never counts as a release, like fences and
  quotes.
- Under an owner account (multi_bot.owner_fallback or merge_account in
  policy.stop_release_accounts) issue.comment, pr.review and api.request comment/review writes
  refuse any body with a release line, so the bot cannot lift a stop as the owner.
- Labels with auto-merge effect: no workflow in the maintained organisations merges on a label,
  so no label refusal is added.
- MULTI-BOT prompt: a release is its own comment with only the formula line; no other stop
  signal may appear in it, or it counts as a new STOPP.
- Version 0.2.2; CHANGELOG entry for #18 and this fix; stray trailing Unreleased section folded
  into 0.2.2.

Ticket: T-20261122-473151443

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01THB2EyNYw5th8eXvfU8evh
@lukisch

lukisch commented Nov 22, 2026

Copy link
Copy Markdown
Contributor Author

Independent review, head afabc94: approved for merge

Measured on macOS (Python 3.12, fresh clone, throwaway venv):

  • ruff clean.

  • Full suite: 529 passed, 7 skipped, in 2 of 2 runs.

  • The new gate tests fail against main src: 7 failed.

  • Owner-account probes for write_denial, each also checked through denial_reason: 17 of 18 behave as specified.

    • Denied:
      • the formula alone and in a multi-line body
      • leading spaces, emphasis plus !, an NBSP inside the formula, and CRLF line endings
      • pr.review bodies
      • api.request to …/comments, with a trailing slash, and with a string body
      • an owner listed via stop_release_accounts, regardless of letter case
    • Allowed, with no false alarm:
      • quoted, indented and "formula plus extra words" lines. None of them would release in the gate either.
      • plain comments, and a comment that discusses the rule with the formula in inline code
      • every comment under the regular bot account
    • Detection and refusal share _is_release, so there is no gap between what the gate would accept as a release and what the bot is allowed to post.
  • Negative controls, all five red:

    Mutation Failed tests
    write_denial not wired into denial_reason 4
    Indented lines release again 2
    Owner never detected 4
    api.request unchecked 2
    pr.review unchecked 1

Residual, not blocking: owner_fallback must be the JSON boolean true. A string "true" in a config layer is not treated as the owner mode. The wrapper writes the boolean, so the current path is covered. Rejecting non-boolean values in config validation would close it.

@lukisch
lukisch marked this pull request as ready for review November 22, 2026 23:37
@ellmos-multi-bot
ellmos-multi-bot merged commit e5cfe64 into main Nov 22, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants